package com.xw.class08;

/**
 * @author: xw
 * @create: 2023/5/17 14:08
 * @description:
 */
public class Test {
    public static void main(String[] args) {
//        int[] arr = new int[] {1,5,6,4,2,9,12,5,89547};
//        int[] bucket = new int[13];
//        for (int i = 0; i < arr.length; i++) {
//            bucket[arr[i]]++;
//            printArray(bucket);
//        }
//        int maxbits = maxbits(arr);
//        System.out.println(maxbits);
        System.out.println(52/((int)Math.pow(10,0)) % 10);

    }

    public static int getDigit(int x, int d) {
        return (x/((int)Math.pow(10,d-1))) % 10 ;
    }

    public static int maxbits(int[] arr) {
        int max = Integer.MIN_VALUE;
        for (int i = 0; i < arr.length; i++) {
            max = Math.max(max, arr[i]);
        }
        int res = 0;
        while (max != 0) {
            res++;
            max /= 10;
        }
        return res;
    }
    public static void printArray(int[] arr) {
        if (arr == null) {
            return;
        }
        for (int i = 0; i < arr.length; i++) {
            System.out.print(arr[i] + " ");
        }
        System.out.println();
    }
}
